<?php echo anchor(base_url(),"Home");?>
<?php echo validation_errors();?>
<?php echo form_open("role/Role/create");?>
<table>
  <tr>
    <td><label for="name">Name</label></td>
    <td><input type="text" name="name" id="name" value="<?php echo set_value('name');?>"/></td>
  </tr>
  <tr>
    <td><label for="description">Description</label></td>
    <td><textarea name="description" id="description" value="<?php echo set_value('description');?>"></textarea></td>
  </tr>
  <tr>
  	<td colspan="2">
  		<table>
  			<tr><td>Resource</td><td>Read</td><td>Write</td><td>Modify</td><td>Delete</td></tr>
  			<tr>
  				<td>User<input type="hidden" name="user_resource" value="1" /></td>
  				<td><input type="checkbox" name="user_perm[]" value="Read"></td>
  				<td><input type="checkbox" name="user_perm[]" value="Write"></td>
  				<td><input type="checkbox" name="user_perm[]" value="Modify"></td>
  				<td><input type="checkbox" name="user_perm[]" value="Delete"></td>
  			</tr>
  			<tr>
  				<td>Role<input type="hidden" name="role_resource" value="2" /></td>
  				<td><input type="checkbox" name="role_perm[]" value="Read"></td>
  				<td><input type="checkbox" name="role_perm[]" value="Write"></td>
  				<td><input type="checkbox" name="role_perm[]" value="Modify"></td>
  				<td><input type="checkbox" name="role_perm[]" value="Delete"></td>
  			</tr>
  			<tr>
  				<td>Article<input type="hidden" name="article_resource" value="3" /></td>
  				<td><input type="checkbox" name="article_perm[]" value="Read"></td>
  				<td><input type="checkbox" name="article_perm[]" value="Write"></td>
  				<td><input type="checkbox" name="article_perm[]" value="Modify"></td>
  				<td><input type="checkbox" name="article_perm[]" value="Delete"></td>
  			</tr>
  			<tr>
  				<td>Plugin<input type="hidden" name="plugin_resource" value="4" /></td>
  				<td><input type="checkbox" name="plugin_perm[]" value="Read"></td>
  				<td><input type="checkbox" name="plugin_perm[]" value="Write"></td>
  				<td><input type="checkbox" name="plugin_perm[]" value="Modify"></td>
  				<td><input type="checkbox" name="plugin_perm[]" value="Delete"></td>
  			</tr>
  		</table>
  	</td>
  </tr>
  <tr>
  	<td><p><input type="submit" value="Submit"/></td>
  	<td></td>
  </tr>
</table>
<?php echo form_close();?>